package com.boot.system.entity;

import com.boot.common.entity.BaseEntity;
import com.boot.system.entity.listener.ModuleOnSetListener;
import com.mybatisflex.annotation.Column;
import com.mybatisflex.annotation.Table;
import lombok.Getter;
import lombok.Setter;
import lombok.experimental.Accessors;

/**
 * 模块实体
 */
@Getter
@Setter
@Accessors(chain = true)
@Table(value = "sys_module", onSet = ModuleOnSetListener.class)
public class SysModule extends BaseEntity {

    /**
     * 模块ID
     */
    @Column(value = "mid")
    private String mid;

    /**
     * 模块名称
     */
    @Column(value = "name")
    private String name;

    /**
     * 是否缓存 1=是 0=否
     */
    @Column(value = "is_cache")
    private Integer isCache;

    /**
     * 是否多选 1=是 0=否
     */
    @Column(value = "is_choice")
    private Integer isChoice;

    /**
     * 操作栏宽度
     */
    @Column(value = "op_width")
    private String opWidth;

    /**
     * 表单宽度
     */
    @Column(value = "form_width")
    private String formWidth;

    /**
     * 表单标签位置
     */
    @Column(value = "form_label_position")
    private String formLabelPosition;

    /**
     * 表单标签宽度
     */
    @Column(value = "form_label_width")
    private String formLabelWidth;

    /**
     * 角色字符串
     */
    @Column(value = "roles")
    private String roles;

    /**
     * 角色数组
     */
    @Column(ignore = true)
    private String[] roleArr;

    /**
     * 接口集合
     */
    @Column(value = "api_json")
    private String apiJson;

    /**
     * 按钮集合
     */
    @Column(value = "btn_json")
    private String btnJson;

    /**
     * 表结构
     */
    @Column(value = "table_json")
    private String tableJson;

}
